# Maintainer: Felix Yan <felixonmars@archlinux.org>
# Maintainer: Filipe Laíns (FFY00) <lains@archlinux.org>
# Contributor: Johannes Dewender  arch at JonnyJD dot net
# Contributor: Ivan Sichmann Freitas <ivansichfreitas@gmail.com>
# Contributor: Brice Maron <brice@bmaron.net>
# Contributor: Nuno Araujo <nuno.araujo at russo79.com>
# Contributor: Steven Allen <steven {at} stebalien {dot} com>

pkgname=python-keyrings-alt
epoch=1
pkgver=4.2.0
_commit=a2ef1a8e15859bb90f499e6be88c14468f246f8e
pkgrel=3
pkgdesc="Alternate keyring implementations"
arch=('any')
url='https://github.com/jaraco/keyrings.alt'
license=('MIT')
depends=('python-keyring' 'python-jaraco.text')
makedepends=('git' 'python-build' 'python-installer' 'python-setuptools-scm' 'python-wheel')
checkdepends=('libgnome-keyring' 'python-pycryptodome' 'python-pycryptodomex' 'python-gobject' 'python-keyring'
              'python-pytest-enabler' 'python-pytest-mypy')
optdepends=('libgnome-keyring: GNOME Integration'
            'python-gobject: GNOME Integration'
            'python-fs'
            'python-pycryptodome: Encrypted file storage')
source=("git+https://github.com/jaraco/keyrings.alt.git#commit=$_commit")
sha512sums=('SKIP')

build() {
  cd keyrings.alt
  python -m build --wheel --no-isolation
}

check() {
  cd keyrings.alt
  pytest
}

package() {
  cd keyrings.alt
  python -m installer --destdir="$pkgdir" dist/*.whl
  install -Dm644 LICENSE -t "$pkgdir"/usr/share/licenses/$pkgname/
}

# vim:set ts=2 sw=2 et:
